<%@ page import="br.com.jambu.cge.Endereco" %>



<div class="fieldcontain ${hasErrors(bean: enderecoInstance, field: 'logradouro', 'error')} required">
	<label for="logradouro">
		<g:message code="endereco.logradouro.label" default="Logradouro" />
		<span class="required-indicator">*</span>
	</label>
	<g:textField name="logradouro" required="" value="${enderecoInstance?.logradouro}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: enderecoInstance, field: 'bairro', 'error')} required">
	<label for="bairro">
		<g:message code="endereco.bairro.label" default="Bairro" />
		<span class="required-indicator">*</span>
	</label>
	<g:textField name="bairro" required="" value="${enderecoInstance?.bairro}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: enderecoInstance, field: 'cidade', 'error')} required">
	<label for="cidade">
		<g:message code="endereco.cidade.label" default="Cidade" />
		<span class="required-indicator">*</span>
	</label>
	<g:textField name="cidade" required="" value="${enderecoInstance?.cidade}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: enderecoInstance, field: 'estado', 'error')} required">
	<label for="estado">
		<g:message code="endereco.estado.label" default="Estado" />
		<span class="required-indicator">*</span>
	</label>
	<g:textField name="estado" required="" value="${enderecoInstance?.estado}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: enderecoInstance, field: 'agente', 'error')} required">
	<label for="agente">
		<g:message code="endereco.agente.label" default="Agente" />
		<span class="required-indicator">*</span>
	</label>
	<g:select id="agente" name="agente.id" from="${br.com.jambu.cge.Agente.list()}" optionKey="id" required="" value="${enderecoInstance?.agente?.id}" class="many-to-one"/>
</div>

<div class="fieldcontain ${hasErrors(bean: enderecoInstance, field: 'cep', 'error')} ">
	<label for="cep">
		<g:message code="endereco.cep.label" default="Cep" />
		
	</label>
	<g:textField name="cep" value="${enderecoInstance?.cep}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: enderecoInstance, field: 'pais', 'error')} ">
	<label for="pais">
		<g:message code="endereco.pais.label" default="Pais" />
		
	</label>
	<g:textField name="pais" value="${enderecoInstance?.pais}"/>
</div>

<div class="fieldcontain ${hasErrors(bean: enderecoInstance, field: 'usuario', 'error')} required">
	<label for="usuario">
		<g:message code="endereco.usuario.label" default="Usuario" />
		<span class="required-indicator">*</span>
	</label>
	<g:select id="usuario" name="usuario.id" from="${br.com.jambu.cge.Usuario.list()}" optionKey="id" required="" value="${enderecoInstance?.usuario?.id}" class="many-to-one"/>
</div>

